
#ifndef LAYERTABLEBOARD_H
#define LAYERTABLEBOARD_H

#include <BLineEdit>
#include <BTableWidget>

using namespace BWE;

class LayerTableBoard : public BTableWidget
{
	BOBJECT(LayerTableBoard);
public:
	LayerTableBoard(BWidget* parent = 0);
	~LayerTableBoard();

protected:
	void slotTableItemClicked(BObject* object, const BValue& value);
	void slotTableWidgetFreshed(BObject* object, const BValue& value);
	void slotTitleEditFocused(BObject* object, const BValue& value);
	void slotTitleEditFinished(BObject* object, const BValue& value);

protected:
	virtual void paintEvent(const BEvent& event);

	virtual void mousePressEvent(const BMouseEvent& event);
	virtual void mouseReleaseEvent(const BMouseEvent& event);
	virtual void mouseMoveEvent(const BMouseEvent& event);

private:
	int			_pressedRow;
	int			_hoveredRow;
	BLineEdit*	_titleEdit;
};

#endif
